package cn.percent.config;


import cn.percent.cache.Cache;
import cn.percent.utils.DBConnectionManager;
import javax.sql.DataSource;
import java.util.HashMap;
import java.util.Map;

public class Configuration {

    private DBConnectionManager dataSource;
    private boolean cacheEnabled = true;
    private String environmentId;



    public boolean isCacheEnabled() {
        return cacheEnabled;
    }

    public void setCacheEnabled(boolean cacheEnabled) {
        this.cacheEnabled = cacheEnabled;
    }

    public String getEnvironmentId() {
        return environmentId;
    }

    public void setEnvironmentId(String environmentId) {
        this.environmentId = environmentId;
    }

    private Cache cache;

    public Cache getCache() {
        return cache;
    }

    public void setCache(Cache cache) {
        this.cache = cache;
    }

    Map<String,MappedStatement> mappedStatementMap = new HashMap<String, MappedStatement>();

    public DBConnectionManager getDataSource() {
        return dataSource;
    }

    public void setDataSource(DBConnectionManager dataSource) {
        this.dataSource = dataSource;
    }

    public Map<String, MappedStatement> getMappedStatementMap() {
        return mappedStatementMap;
    }

    public void setMappedStatementMap(Map<String, MappedStatement> mappedStatementMap) {
        this.mappedStatementMap = mappedStatementMap;
    }
}
